var tableModel = new Starcor.S67.MVC.Model("table");
tableModel.query=function(params){
		tableModel.data = {'pager':{
			'num':0,
			'count':0
		},
		'item':[
		{'id':'sdasda1','name':'meimei','age':'25','height':'165cm','favourite':'吃饭睡觉打豆豆'},
		{'id':'sdasda2','name':'meimei','age':'25','height':'165cm','favourite':'吃饭睡觉打豆豆'},
		{'id':'sdasda3','name':'meimei','age':'25','height':'165cm','favourite':'吃饭睡觉打豆豆'},
		{'id':'sdasda4','name':'meimei','age':'25','height':'165cm','favourite':'吃饭睡觉打豆豆'},
		{'id':'sdasda5','name':'meimei','age':'25','height':'165cm','favourite':'吃饭睡觉打豆豆'},
		{'id':'sdasda6','name':'meimei','age':'25','height':'165cm','favourite':'吃饭睡觉打豆豆'},
		{'id':'sdasda7','name':'meimei','age':'25','height':'165cm','favourite':'吃饭睡觉打豆豆'},
		{'id':'sdasda8','name':'meimei','age':'25','height':'165cm','favourite':'吃饭睡觉打豆豆'},
		{'id':'sdasda9','name':'meimei','age':'25','height':'165cm','favourite':'吃饭睡觉打豆豆'},
		{'id':'sdasda10','name':'meimei','age':'25','height':'165cm','favourite':'吃饭睡觉打豆豆'},
		{'id':'sdasda11','name':'meimei','age':'25','height':'165cm','favourite':'吃饭睡觉打豆豆'},
		]
	};
		tableModel.disEvent('query', tableModel.data);
};
tableModel.add=function(params){
	if (!params.name || !params.tag|| !params.active_duration){
		return;
	}
	
	NBOSS.ajax(params,'create',function(data){
		if (data.code=='000000'){
			window.top.NBOSS.Alert('提示','添加消息成功');

			
		}else{
			 window.top.NBOSS.Alert('错误',data.reason);
		}
		tableModel.disEvent('add');
	},'table');	
};




	